<template>
  <div class="nav-bar" :style="{background:bgColor,color:color}">
    <div class="left">
      <slot name="left"></slot>
    </div>
    <div class="center">
      <slot name="center"></slot>
    </div>
    <div class="right">
      <slot name="right"></slot>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    color: {
      type: String,
      default: "#666",
    },
    bgColor: {
      type: String,
      default: "#fff",
    },
  },
};
</script>

<style scoped lang="less">
.nav-bar {
  display: flex;
  align-items: center;
  height: 5vh;
  box-shadow: 0 0 3px rgba(100, 100, 100, 0.5);
  font-size: 1.8vh;
  text-align: center;
  .left,
  .right {
    height: 100%;
    width: 15vw;
  }
  .center {
    flex: 1;
  }
}
</style>